package com.dmz.resold.apartment.csp;

/**
 * @author lee
 */
public class ConnectParam {
    //接收模式
    public final String RECV_MODE_BYLENGTH = "ByLength";
    public final String RECV_MODE_DELIMITER = "Delimiter";

    //名称
    public String name;

    //服务器ip
    public String ip;

    //服务器端口
    public int port;

    //连接超时时间
    public int connectTimeoutMillSeconds = 60000;

    //TCP_NODELAY
    public boolean tcpNoDelay = true;

    //发送缓冲池大小
    public int sendBufferSize;

    // 接受缓冲池大小
    public int receiveBufferSize;

    //接受回复信息模式
    public String recvMode = this.RECV_MODE_BYLENGTH;

    //长度
    public int length;

    //分隔符
    public Delimiter delimiter;

    //重复查询时间
    public int clientTryTimes;

    public int getConnectTimeoutMillSeconds() {
        return connectTimeoutMillSeconds;
    }

    public int getClientTryTimes() {
        return clientTryTimes;
    }

    public void setClientTryTimes(int clientTryTimes) {
        this.clientTryTimes = clientTryTimes;
    }

    public void setConnectTimeoutMillSeconds(int connectTimeoutMillSeconds) {
        this.connectTimeoutMillSeconds = connectTimeoutMillSeconds;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public int getLength() {
        return length;
    }

    public void setLength(int length) {
        this.length = length;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }

    public int getReceiveBufferSize() {
        return receiveBufferSize;
    }

    public void setReceiveBufferSize(int receiveBufferSize) {
        this.receiveBufferSize = receiveBufferSize;
    }

    public String getRecvMode() {
        return recvMode;
    }

    public void setRecvMode(String recvMode) {
        this.recvMode = recvMode;
    }

    public int getSendBufferSize() {
        return sendBufferSize;
    }

    public void setSendBufferSize(int sendBufferSize) {
        this.sendBufferSize = sendBufferSize;
    }

    public boolean isTcpNoDelay() {
        return tcpNoDelay;
    }

    public void setTcpNoDelay(boolean tcpNoDelay) {
        this.tcpNoDelay = tcpNoDelay;
    }

    public Delimiter getDelimiter() {
        return delimiter;
    }

    public void setDelimiter(Delimiter delimiter) {
        this.delimiter = delimiter;
    }


}
